<?php 
## include required files
/*******************************/
require_once '../model/faqs.php';
/*******************************/
## Create Objects
/*******************************/
$faqObj = new Model_FAQ();
/*******************************/

if($_GET['id']!='') {
	$faq_id = base64_decode($_GET['id']);
	$faqArray = $faqObj->getFaqDetailsById($faq_id);
	$faqcatName = $faqObj->getFaqCategoryNameById($faqArray['faq_category_id']);
	$smarty->assign('faqArray', $faqArray);
	$smarty->assign('faqcatName', $faqcatName);
}

## Set active class variable for left menu
$smarty->assign('activeclass', 'faqs');
$smarty->assign('mainmenu', '2');

## Unset all the objects created which are on this page
unset($faqObj);

$smarty->display(TEMPLATEDIR_ADMIN. 'faq/faqdetails.tpl');
unset($smarty);
?>